<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <title>慢性病报销系统V1.0</title>
    <base href="<%=basePath%>">  
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
    <meta name="renderer" content="webkit">
    <link rel="stylesheet" href="css/styles.css">
    <link rel="stylesheet" href="css/admin.css">
    <link rel="stylesheet" href="css/pintuer.css">
    <script src="js/jq.js"></script>   
   
    
</head>

<body style="background-color:#f2f9fd;">
<div class="header bg-main">
  <div class="logo margin-big-left fadein-top">
<h1><img src="images/logo.jpg" class="radius-circle rotate-hover" height="50" alt="" />慢性病报销系统</h1>
    
  </div>
  <div class="head-l" ><a href="page/user/uduself.jsp" target="right" style="color:#FFF" >
  <span class="icon-user"></span> 欢迎 ${user[0].name}</a>&nbsp;&nbsp;
  <a class="button button-little bg-green" href="" target="_blank" >
  <span class="icon-home"></span> 首页</a> &nbsp;&nbsp;
  <a class="button button-little bg-red" href="LogoutServlet">
  <span class="icon-power-off"></span> 退出登录</a> </div>
</div>

<div class="leftnav">
  <div class="leftnav-title"><strong><span class="icon-list"></span>菜单列表</strong></div>
  <c:forEach items="${listm }" var="lm">
  	<c:if test="${lm.menupId==0 }">
  	<!-- 若父节点id为0，该菜单为1级菜单 -->
  		<h2><span class="icon-user"></span>${lm.menuName }</h2>
  		<ul style="display:block">
  			<!-- 在1级菜单里循环 -->
  			<c:forEach items="${listm }" var="lm2">
  				<!-- ${mid}是存在session里的，用户所属角色所对应的菜单 -->
  				<c:forEach items="${mid}" var="m">
  					<!-- 在1级菜单内，A菜单的id(lm.menuId)若等于B菜单的Pid(lm2.menupId),则A菜单为B菜单父菜单，
  					     同时要求，在session里的菜单C(m.menuId)，要与B菜单的id(lm2.menuId)相同，则显示此菜单 -->
  					<c:if test="${lm.menuId eq lm2.menupId and m.menuId eq lm2.menuId}">
  					<li><a href="${lm2.url }" target="right"><span class="icon-caret-right">
  					</span>${lm2.menuName}</a></li>
  					</c:if>
  				</c:forEach>
  			</c:forEach>
  		</ul>
  	</c:if>
  	
  </c:forEach>
  <!-- 
  <h2><span class="icon-user"></span>系统设置</h2>
  <ul style="display:block">
    <li><a href="RoleServlet?method=findRole&&fr=role" target="right"><span class="icon-caret-right"></span>角色管理</a></li>
    <li><a href="UserServlet?method=findUser&&index=1" target="right"><span class="icon-caret-right"></span>用户管理</a></li>
    <li><a href="javascript:void(0)" target="right"><span class="icon-caret-right"></span>权限管理</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>行政区域管理</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>农合机构管理</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>慢病分类管理</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>医疗机构管理</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>慢病政策设置</a></li>
    </ul>   
     <h2><span class="icon-user"></span>业务办理</h2>
  <ul >
    <li><a href="#" target="right"><span class="icon-caret-right"></span>家庭档案管理</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>农民档案管理</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>参合缴费登记</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>慢病证管理</a></li>
    <li><a href="#" target="right"><span class="icon-caret-right"></span>慢病报销</a></li>
    </ul> 
    <h2><span class="icon-user"></span>统计报表</h2>
  <ul >
    <li><a href="#" target="right"><span class="icon-caret-right"></span>慢性病报销情况</a></li>
    </ul>   
     -->
</div>

<script type="text/javascript">
$(function(){
  $(".leftnav h2").click(function(){
	  $(this).next().slideToggle(200);	
	  $(this).toggleClass("on"); 
  })
  $(".leftnav ul li a").click(function(){
	    $("#a_leader_txt").text($(this).text());
  		$(".leftnav ul li a").removeClass("on");
		$(this).addClass("on");
  })
});
</script>
<ul class="bread">
  <li><a href="{:U('Index/info')}" target="right" class="icon-home"> 首页</a></li>
  <li><a href="##" id="a_leader_txt">欢迎界面</a></li>
  <li><b>当前语言：</b><span style="color:red;">中文</php></span>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;切换语言：<a href="##">中文</a> &nbsp;&nbsp;<a href="##">英文</a> </li>
</ul>
<div class="admin">
  <iframe scrolling="auto" rameborder="0" src="select.jsp" name="right" width="100%" height="100%"></iframe>
</div>
<div style="text-align:center;">
<p>来源:<a href="http://www.mycodes.net/" target="_blank">源码之家</a></p>
</div>
</body>

</html>
